Conversation
Adds smoke-test.ps1 and smoke-test.sh to every release zip. Start the simulator, run one of them, and it exercises the whole documented contract - 25 checks - printing PASS or FAIL for each. It exits 1 when a check fails and 2, with an explanation, when the simulator is not reachable, so it also works as a CI gate. The container smoke test in CI now runs that same script instead of a few inline curl calls, so the tool that ships to users is exercised on every pull request and cannot rot unnoticed. Also documents how to drive the API from a browser: /healthz and /version open directly, and for the POST endpoint you open /healthz first and use fetch from the console - being on the simulator's own origin is what avoids CORS, since no CORS policy is configured. Fixes /version reporting the commit sha twice (1.0.3+<sha>.<sha>): the release pipeline appends it to InformationalVersion and the SDK appended it again. IncludeSourceRevisionInInformationalVersion is now off. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Every release zip now carries a script that proves the download works. Start the simulator, run
smoke-test.ps1orsmoke-test.sh, and it exercises the whole documented contract — 25 checks — printing PASS or FAIL for each.Exit codes:
0all passed,1something failed (with expected vs actual),2the simulator is not reachable. That makes it usable as a CI gate, not just a demo.The container smoke test in CI now runs that same script instead of a few inline curl calls, so the tool that ships to users is exercised on every pull request and cannot rot unnoticed.
Contract impact
/versionnow reports1.0.4+<sha>instead of1.0.3+<sha>.<sha>. The release pipeline appends the commit sha toInformationalVersionand the SDK appended it a second time;IncludeSourceRevisionInInformationalVersionis off now. The shape of the response is unchanged.Driving it from a browser
/healthzand/versionopen directly. The validation endpoint is POST-only, so a URL alone will not reach it — openhttp://localhost:5000/healthzfirst, then usefetchfrom the console. Being on the simulator's own origin is what avoids CORS, since no CORS policy is configured.Verified in a real browser: same-origin fetch returns
200with bodytrue,400for invalid JSON,200for a bare scalar.Checklist
master, so it targetsmasterby designdotnet testpasses locally — 131 testsdotnet format --verify-no-changesis cleansmoke-test.shis stored with LF in git, so the shebang survives on LinuxVERSION.mdbumped to1.0.4andCHANGELOG.mdhas a[1.0.4]sectionHow to verify after release